import React, { Children } from "react";
import ReactDOM from "react-dom";

import { Button, SpaceWraper } from "@teach_wmg_21";

import { KSideMenu } from '@src/core'

import './index.scss';

export default class ComTest extends React.Component {

    constructor(props) {
        super(props);

        this.state = {
            menuTree: [
                {
                    id: 90,
                    name: '介绍',
                    full_name: '介绍',
                    url: '/Intro',
                    active: false,
                    full_screen: false
                },
                // {
                //     id: 90,
                //     name: '自动化',
                //     full_name: '自动化',
                //     url: '/Auto',
                //     active: false,
                //     full_screen: false
                // }, 
                {
                    id: 91,
                    name: '代码在线',
                    full_name: '代码在线',
                    url: '/DocLive',
                    active: false,
                    full_screen: false
                }, {
                    id: 91,
                    name: '按纽',
                    full_name: '按纽',
                    url: '/Button',
                    active: false,
                    full_screen: false
                }, {
                    id: 93,
                    name: '组容器',
                    full_name: '组容器',
                    url: '/SpaceWraper',
                    active: false,
                    full_screen: false
                }, {
                    id: 93,
                    name: '内容弹框',
                    full_name: '内容弹框',
                    url: '/Modal',
                    active: false,
                    full_screen: false
                }, {
                    id: 93,
                    name: '提示框',
                    full_name: '提示框',
                    url: '/Alert',
                    active: false,
                    full_screen: false
                }
            ]
        }
    }


    componentDidMount() {

    }




    render() {
        return (
            <div className="keda-layout" >

                <div className="keda-layout-header" >
                    <div className="keda-layout-header-left">
                        <div className="pro_title">
                            <img src=""></img>
                        </div>
                        <div class="kd_icon pro_divider">
                            <img src="" />
                        </div>
                        <div className="pro_sub_title">视讯平台组件库 v1.0.0</div>
                    </div>

                </div>
                <div className="keda-layout-body" >
                    <div className="keda-layout-side" >
                        <KSideMenu menuTree={this.state.menuTree} leafNodeClick={(item) => console.log(item)} />
                    </div>
                    <div className="keda-layout-side-divider" >
                    </div>
                    <div className="keda-layout-main" >
                        {
                            this.props.children
                        }
                    </div>
                </div>


            </div>

        );
    }
}